package org.origin.ferret.system.model.vo.user;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

/**
 * 系统用户响应-实体类
 *
 * @author ferret
 * @version 2024-05-08
 */
@Data
@Accessors(chain = true)
@Schema(description = "系统用户响应-实体类")
public class SysUserVo {

    @Schema(description = "主键")
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long id;

    @Schema(description = "创建人ID")
    private String createBy;

    @Schema(description = "创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;

    @Schema(description = "更新人ID")
    private String updateBy;

    @Schema(description = "更新时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date updateTime;    // 更新时间

    @Schema(description = "账户")
    private String account;

    @Schema(description = "名称")
    private String name;

    @Schema(description = "头像")
    private String photo;

    @Schema(description = "手机")
    private String phone;

    @Schema(description = "性别")
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Integer gender;

    @Schema(description = "生日")
    @JsonFormat(pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date birth;

    @Schema(description = "证件")
    private String identity;

    @Schema(description = "状态")
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Integer status;

    @Schema(description = "性别描述")
    private String genderLabel;

    @Schema(description = "状态描述")
    private String statusLabel;
}
